package com.prj.ufdm.cloud.ms.test.bpo._impl.dbtable;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.prj.ufdm.cloud.ms.core.bpo._impl.BaseBPOImpl;
import com.prj.ufdm.cloud.ms.test.bpo.dbtable.DbTableBPO;
import com.prj.ufdm.cloud.ms.test.dao.dbtable.DbTableDao;
import com.prj.ufdm.cloud.ms.test.model.dbtable.DbTable;

/**
 * DESC: 数据库表服务接口实现类 <br>
 * @author 胡义振
 * @date 2020年1月17日
 */
@Service(value="dbTableBPO")
public class DbTableBPOImpl extends BaseBPOImpl<DbTableDao, DbTable>  implements DbTableBPO {

    @Autowired
    private  DbTableDao dbTableDao;

	@Override
	public DbTable doGetTableByTableName(String tableName) {
		List<DbTable>  dbTableList = dbTableDao.selectListByTableName(tableName);
		if(dbTableList!=null && dbTableList.size()>0) {
			return dbTableList.get(0);
		}
		return null;
	}
}
